Repository navigation
fix(apple): define in6_ifreq locally so iOS targets build with libc 0.2.190 - #192
Draft
andrewgazelka wants to merge 1 commit into
Draft
andrewgazelka wants to merge 1 commit into
andrewgazelka wants to merge 1 commit into
Conversation
….2.190 libc 0.2.190 only exposes in6_ifreq on macOS (netinet6/in6_var.h is not in the iOS SDK), which broke cargo check for aarch64-apple-ios and aarch64-apple-ios-sim. Define the struct in the darwin module, sized to the 0x120 bytes encoded in SIOCGIFAFLAG_IN6, and add iOS targets to CI. Assisted-by: Claude:claude-sonnet-5-5
bisand
added a commit
to bisand/kvad
that referenced
this pull request
Oct 18, 2026
Phase 0 of docs/relay-plan.md needs a phone column: the phone itself on mobile data, behind the carrier's NAT alone, not a laptop on its hotspot. - tools/relay-probe: the core moves into a library (src/lib.rs): tickets, the post-quantum endpoint with no port mapping, the dialler's ping loop, path names and the summary table. The command keeps its flags and its output, --bind included; `listen` stays in main.rs. - apps/phone: a Network test under More and on the Connect screen, which dials with that library on a tokio runtime of its own. Paste the ticket from the Mac, Start/Stop, the path as it changes, the command's table and log. The phone's probe key is a file in the app's container until the Keychain lands; its id is shown and copied for the relay's allow list. The screen stays awake during a run. - libc held at 0.2.189 for iOS: netdev 0.46 (iroh's netwatch) uses libc::in6_ifreq, which 0.2.190 made macOS-only (shellrow/netdev#192). Checked in the iOS simulator against `relay-probe listen --relay https://relay2.kvad.eu` on this Mac: opened on the relay, LAN after 0.12 s, 0.9 ms median. Builds for aarch64-apple-ios too.
bisand
added a commit
to bisand/kvad
that referenced
this pull request
Oct 18, 2026
* Run the relay probe from the iPhone: a Network test screen Phase 0 of docs/relay-plan.md needs a phone column: the phone itself on mobile data, behind the carrier's NAT alone, not a laptop on its hotspot. - tools/relay-probe: the core moves into a library (src/lib.rs): tickets, the post-quantum endpoint with no port mapping, the dialler's ping loop, path names and the summary table. The command keeps its flags and its output, --bind included; `listen` stays in main.rs. - apps/phone: a Network test under More and on the Connect screen, which dials with that library on a tokio runtime of its own. Paste the ticket from the Mac, Start/Stop, the path as it changes, the command's table and log. The phone's probe key is a file in the app's container until the Keychain lands; its id is shown and copied for the relay's allow list. The screen stays awake during a run. - libc held at 0.2.189 for iOS: netdev 0.46 (iroh's netwatch) uses libc::in6_ifreq, which 0.2.190 made macOS-only (shellrow/netdev#192). Checked in the iOS simulator against `relay-probe listen --relay https://relay2.kvad.eu` on this Mac: opened on the relay, LAN after 0.12 s, 0.9 ms median. Builds for aarch64-apple-ios too. * Link the iPhone app for iOS 17 when cargo builds it alone A bare cargo build for aarch64-apple-ios linked for iOS 10, older than Skia's prebuilt objects (iOS 12), and failed on ___chkstk_darwin; Xcode builds were unaffected, since it passes project.yml's deployment target. apps/phone/.cargo/config.toml sets the same 17.0 for cargo, without overriding Xcode's.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
libc 0.2.190 only exposes
in6_ifreqon macOS (netinet6/in6_var.his not in the iOS SDK), socargo check --target aarch64-apple-ios-simfails withcannot find type in6_ifreq in crate libc(libc 0.2.189 still had it; I only reproduced the ios-sim target).This defines the struct in
src/os/darwin/ipv6_addr_flags.rs, padded to 0x120 bytes (the size encoded inSIOCGIFAFLAG_IN6, asserted at compile time), and addsaarch64-apple-iosandaarch64-apple-ios-simcargo checkjobs to CI.Measured locally (Xcode 27 beta SDK, stable toolchain, libc pinned to 0.2.190): before,
cargo check --target aarch64-apple-ios-simfails with the error above; after,aarch64-apple-ios-sim,aarch64-apple-iosandaarch64-apple-darwincheck clean,cargo testpasses (33 tests) andlist_interfaceson macOS still reports interface flags. Not run on a device or simulator. The new CI job is untested until it runs here.AI disclosure: written with Claude (Sonnet); commit carries an
Assisted-by:trailer.